# @Time    :2025/3/29 0:31
"""
使用匿名函数和 sorted 函数对以下列表
students = [{"name": "Alice", "score": 85},
{"name": "Bob", "score": 70},
{"name": "Charlie", "score": 90}]
按照学生的成绩从高到低进行排序。

"""

students = [{"name": "Alice", "score": 85},
            {"name": "Bob", "score": 70},
            {"name": "Charlie", "score": 90}]

#students.sort(key=lambda stu:stu["score"],reverse=True)


student=sorted(students,key=lambda stu:stu["score"],reverse=True)

print(student)